package com.cskaoyan.vo.goods;

import com.cskaoyan.bean.goods.Goods;
import com.cskaoyan.bean.goods.GoodsAttribute;
import com.cskaoyan.bean.goods.GoodsProduct;
import com.cskaoyan.bean.goods.GoodsSpecification;
import com.cskaoyan.bean.market.Brand;
import com.cskaoyan.bean.market.Issue;
import com.cskaoyan.bean.promotion.GrouponRules;
import lombok.Data;

import java.util.List;

/**
 * description:微信小程序的GoodsDetail功能的返回封装数据的bean
 * author:houzhitao@139.com
 */
@Data
public class WxGoodsDetailVo {

    /**
     * specificationList : [{"name":"2131","valueList":[{"id":267,"goodsId":1181015,"specification":"2131","value":"213","picUrl":"","addTime":"2021-04-12 11:05:13","updateTime":"2021-04-12 11:05:13","deleted":false}]}]
     * groupon : []
     * issue : [{"id":2,"question":"使用什么快递发货？","answer":"严选默认使用顺丰快递发货（个别商品使用其他快递），配送范围覆盖全国大部分地区（港澳台地区除","addTime":"2018-02-01 00:00:00","updateTime":"2018-02-01 00:00:00","deleted":false},{"id":3,"question":"如何申请退货？","answer":"1.自收到商品之日起30日内，顾客可申请无忧退货，退款将原路返还，不同的银行处理时间不同，","addTime":"2018-02-01 00:00:00","updateTime":"2018-02-01 00:00:00","deleted":false},{"id":4,"question":"如何开具发票？","answer":"1.如需开具普通发票，请在下单时选择\u201c我要开发票\u201d并填写相关信息（APP仅限2.4.0及以","addTime":"2018-02-01 00:00:00","updateTime":"2018-02-01 00:00:00","deleted":false}]
     * userHasCollect : 0
     * comment : {"data":[],"count":0}
     * attribute : [{"id":897,"goodsId":1181015,"attribute":"123","value":"132","addTime":"2021-04-12 11:05:13","updateTime":"2021-04-12 11:05:13","deleted":false}]
     * brand : {"id":1001002,"name":"内野制造商","desc":"严选从世界各地挑选毛巾，最终选择了为日本内野代工的工厂，追求毛巾的柔软度与功能性。品质比肩商场几百元的毛巾。","picUrl":"http://yanxuan.nosdn.127.net/8ca3ce091504f8aa1fba3fdbb7a6e351.png","sortOrder":10,"floorPrice":29,"addTime":"2018-02-01 00:00:00","updateTime":"2018-02-01 00:00:00","deleted":false}
     * productList : [{"id":267,"goodsId":1181015,"specifications":["213"],"price":123,"number":123,"url":"http://182.92.235.201:8083/wx/storage/fetch/tan4h7yjlj1idju5a8em.jpg","addTime":"2021-04-12 11:05:13","updateTime":"2021-04-12 17:40:05","deleted":false}]
     * info : {"id":1181015,"goodsSn":"1441463544","name":"12432","categoryId":1005007,"brandId":1001002,"gallery":["http://182.92.235.201:8083/wx/storage/fetch/9x9m8fspu7rey6xrt197.jpg"],"keywords":"13","brief":"123","isOnSale":true,"sortOrder":100,"picUrl":"http://182.92.235.201:8083/wx/storage/fetch/eqyyo8vfwbo8jtzhgov2.png","isNew":false,"isHot":true,"unit":"1","counterPrice":14,"retailPrice":124,"addTime":"2021-04-12 11:05:13","updateTime":"2021-04-12 11:05:13","deleted":false,"detail":"<p>12<\/p>"}
     */

    private Long userHasCollect;  //根据商品id作为value_id查询collect中数量
    private WxGoodsDetailSonCommentVo comment;  //根据商品id作为value_id查询comment中数量和list详情
    private Brand brand;    //根据查出的商品info的brandId作为id在brand中查询brand详情
    private Goods info;      //根据id查询商品详情,（查询结果将share_url赋值为null）
    private List<WxGoodsDetailSonSpecificVo> specificationList; //根据商品id作为goods_id在specification表中查询相关详情，并且把specification作为name属性
    private List<GrouponRules> groupon;  // 根据商品id作为goods_id查询groupon_rules详情
    private List<Issue> issue; //在issue表中查出全部信息
    private List<GoodsAttribute> attribute; //根据商品id作为goods_id在attribute中查询
    private List<GoodsProduct> productList; //根据商品id作为goods_id在product中查询详情

}
